/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package beans;

import dao.impl.HistoricoDaoImpl;
import java.util.List;
import javax.faces.bean.ManagedBean;
import javax.faces.bean.RequestScoped;
import model.Historico;

/**
 *
 * @author rafael
 */
@ManagedBean
@RequestScoped
public class BeanHistorico {

    /**
     * Creates a new instance of BeanHistorico
     */
    public BeanHistorico() {
    }

    public List<Historico> getHistoricoCompras(Integer pkId) {
        return new HistoricoDaoImpl().selectByUsuarioCompras(pkId);
    }
    public List<Historico> getHistoricoVendas(Integer pkId) {
        return new HistoricoDaoImpl().selectByUsuarioVendas(pkId);
    }
}
